<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
	    		xmlns:ui="http://java.sun.com/jsf/facelets"
	  			xmlns:h="http://java.sun.com/jsf/html"
	  			xmlns:f="http://java.sun.com/jsf/core"
	  			xmlns:s="http://jboss.com/products/seam/taglib"
				xmlns:a4j="http://richfaces.org/a4j"
				xmlns:a="http://richfaces.org/a4j"
				xmlns:rich="http://richfaces.org/rich">
	
	<a4j:form ajaxSubmit="true">
		<h:panelGrid columns="2">
				<h:outputText value="Number of Vouchers" class="label"></h:outputText>
				<rich:inputNumberSlider minValue="1"  maxValue="100" value="#{voucherGenerator.numberOfVouchers}" showInput="false" />
				<h:outputText value="Validity period in days" class="label"></h:outputText>
				<rich:inputNumberSlider minValue="1"  maxValue="365" value="#{voucherGenerator.validityPeriod}" showInput="false" />
				<h:outputText value="Money value" class="label"></h:outputText>
				<rich:inputNumberSlider minValue="1"  maxValue="10000" value="#{voucherGenerator.value}" showInput="false" />
		</h:panelGrid>
		<a:commandButton id="findVoucherRequests" value="generate" action="#{voucherGenerator.generate}" />
		&#160;
		<a:status>
			<f:facet name="start">
				<h:graphicImage value="/img/spinner.gif"/>
			</f:facet>
		</a:status>
	</a4j:form>
	<rich:spacer height="20" />	
	<div class="entry errors">
		<rich:messages globalOnly="true"/>
	</div>	
				
</ui:composition>